import Vue from 'vue'
import Router from 'vue-router'



// const Login = () => import("@/views/Login.vue")   //引入登陆页面
 
Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      redirect: '/login'
    },{
      path: '/login',
      name: 'login',
      component: () => import('@/views/Login.vue'),
      meta: {
        title: "登录"
      }
    },{
      path: '/home',
      name: 'home',
      component: () => import('@/views/home'),
      redirect: 'firstPage',
      children: [
        {
          path: "firstPage",
          name: "firstPage",
          component: () => import('@/views/child/firstPage'),
          meta: {
            title: "首页"
          }
        }

      ]
    }
  ]
})
